<?php

namespace ephalcon\session\adapter;

use libraries\CommUtils;
class Redis extends \Phalcon\Session\Adapter\Redis
{
	public function destroy( $sid = null )
	{
		if( is_null )
		{
			
		}
	}

	/** 
	 *
	 */
	public function regenerateId($deleteOldSession = true) 
	{
		if( $deleteOldSession )
		{
			$this->destroy();
			$this->setId( CommUtils::getUUIDNoDash() );
		}	
		else
		{
			$this->setId( CommUtils::getUUIDNoDash() );
				
			foreach( $_SESSION as $k => $v )
			{
				$this->set( $k, $v );
			}
			
		}
		
		
	}
	
}

?>